# This file is part of BlackArch Linux ( https://www.blackarch.org/ ).
# See COPYING for license details.

pkgname=python2-regex
_pkgname=regex
pkgver=2020.7.14
pkgrel=2
pkgdesc='Alternative regular expression module, to replace re.'
url='https://pypi.org/project/regex/#files'
arch=('x86_64' 'aarch64')
license=('MIT')
depends=('python2')
makedepends=('python2-setuptools')
source=("https://files.pythonhosted.org/packages/source/${_pkgname::1}/$_pkgname/$_pkgname-$pkgver.tar.gz")
sha512sums=('7c782259686cd94c54ce688104cc1b7cada5bf5d09cd74daf01672f8ef01747b11ad9189279e5f9f1dee7cbb7ad827641a359326078e5587153bc0cffcb01267')

build() {
  cd "$_pkgname-$pkgver"

  python2 setup.py build
}

package() {
  cd "$_pkgname-$pkgver"

  python2 setup.py install --root="$pkgdir" --prefix=/usr -O1 --skip-build
}

